package com.mgfireworks.mgplatform.mgshop.index;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("/")
public class IndexController {
	@Autowired
	private IndexService indexService;
	
	/**
	 * 首页
	 */
	@RequestMapping("/index")
	public void index(Model model){
		model.addAttribute("listRecommendProducts", indexService.getRecommendProducts());
	}
}
